/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package com.nuboat.easyjsf.action;

import java.util.LinkedList;
import java.util.List;
import javax.enterprise.context.SessionScoped;
import javax.faces.bean.ManagedBean;
import javax.faces.component.html.HtmlCommandLink;

/**
 *
 * @author nuboat
 */
@SessionScoped
@ManagedBean
public class MenuAction extends BaseAction {

    private List<String> list;
    private HtmlCommandLink link;

    public MenuAction() {
        list = new LinkedList<String>();
        list.add("index");
        list.add("session");
        list.add("localization");
    }

    public String redirectto() {
        return "/xhtml/"+link.getValue().toString();
    }

    /**
     * @return the str
     */
    public HtmlCommandLink getLink() {
        return link;
    }

    /**
     * @param str the str to set
     */
    public void setLink(HtmlCommandLink link) {
        this.link = link;
    }

    /**
     * @return the list
     */
    public List<String> getList() {
        return list;
    }

    /**
     * @param list the list to set
     */
    public void setList(List<String> list) {
        this.list = list;
    }

    
}
